package org.artifact.core.util;

import java.util.Collection;
import java.util.Map;

public class ClassUtil {

	public static boolean isMap(String className) {
		try {
			Class<Object> c = cn.hutool.core.util.ClassUtil.loadClass(className);
			return Map.class.isAssignableFrom(c);
		} catch (Exception e) {
			return false;
		}
	}
	
	public static boolean isCollection(String className) {
		try {
			Class<Object> c = cn.hutool.core.util.ClassUtil.loadClass(className);
			return Collection.class.isAssignableFrom(c);	
		} catch (Exception e) {
			return false;
		}
	}
}
